<%@ page language="java" import="util.*, entity.*, java.util.*, org.displaytag.tags.*" %>
<%@ taglib uri="http://displaytag.sf.net" prefix="display" %>

<%-- 
    Document   : FileUploadTest
    Created on : 2008年10月3日, 上午11:25:36
    Author     : Francis
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">

<html>  
    <head>
        <title>File Upload</title>
        <meta http-equiv="Content-Type" content="text/html; charset=big5" />

         <style type="text/css" media="all">
      @import url("css/maven-base.css");
      @import url("css/maven-theme.css");
      @import url("css/site.css");
      @import url("css/screen.css");
  </style>
   

    </head>
    <body>
        <%
        String categoryID = request.getParameter("cat");
        if (categoryID != null) {
            List<entity.Book> books = BookService.getByCategory(categoryID);
            request.setAttribute("books", books);
        }                    
        %>
 
        <display:table name="${books}">
            <display:column property="bookID" title="ID" />
            <display:column property="name" />
            <display:column property="quantity" />
            <display:column property="statusCode" />            
        </display:table>

        <br/>

        <p><font size="5"color="#FF0000"><b>檔案上傳</b></font></p>

        <form name="upload" enctype="multipart/form-data" method="post" action="FileUploadTest2">
            <p>上傳檔案： <input type="file" name="image1" size="20" maxlength="20" /> </p>
            <p>檔案說明： <input type="text" name="description" size="30" maxlength="50" /> </p>
            <p> <input type="submit"value="上傳" /> <input type="reset" value="清除" /> </p>
        </form>

    </body>
</html>  